﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using NeuralNetworks.ActivationFunctions;
using NeuralNetworks.Layers;

namespace NeuralNetworks.FileParsing
{
    class ActvFunction : LayerPart
    {
        private IActivationFunction actvFun;

        public ActvFunction(String function)
        {
            actvFun = ActivationFunctionFactory.getFunction(function);
        }

        public void apply(Layer current, Layer next)
        {
            if (current != null)
            {
                ((ActivationLayer)current).ActvFunction = actvFun;
            }
        }
    }
}
